{% extends 'base.html' %}
{% block title %}{{ article.title }}|魏先森的博客|做一个有内涵的知识分享者{% endblock %}
{% block body %}

<script>window._bd_share_config={"common":{"bdSnsKey":{},"bdText":"","bdMini":"2","bdMiniList":false,"bdPic":"","bdStyle":"0","bdSize":"16"},"slide":{"type":"slide","bdImg":"2","bdPos":"left","bdTop":"208.5"},"image":{"viewList":["qzone","tsina","tqq","renren","weixin"],"viewText":"分享到：","viewSize":"16"}};with(document)0[(getElementsByTagName('head')[0]||body).appendChild(createElement('script')).src='http://bdimg.share.baidu.com/static/api/js/share.js?v=89860593.js?cdnversion='+~(-new Date()/36e5)];</script>
        <section class="section">
        <div class="container">

            <article class="card blog">
                <div style="float: right;position: relative;">
                    <h3>
                        {% if article.category == '0' %}
                            <span class="label label-info">原创</span>
                        {% elif article.category == '1' %}
                            <span class="label label-warning">转载</span>
                        {% endif %}
                    </h3>
                </div>
                <div class="card__header">
                    <h1 style="font-size: 19px">{{ article.title }}</h1>
                    <small>
                        <span>本文作者：<span class="badge label-info">{{ article.author }}</span></span>
                        <span>发布时间：{{ article.created_time }}</span>
                        <span>浏览（{{ article.read }}）</span>
                        <span>评论（<span  id="changyan_count_unit"></span>）</span>
                        <span>分类：{{ article.get_categories }}</span>
                    </small>
                </div>
                <div class="card__body">
                    <script type="text/javascript">
                        /*960*90 创建于 2017/10/19*/
                        var cpro_id = "u3117251";
                    </script>
                    <script type="text/javascript" src="http://cpro.baidustatic.com/cpro/ui/c.js"></script>

                    <div id="test-editormd-view2">
                        <textarea id="append-test" style="display:none;">
{{ article.body }}
                </textarea>
                    </div>
                </div>
            <div class="blog__arthur">
                    <div class="blog__arthur-contents">
                        <div style="float: left;display: inline-block">
                            <h2>本文作者：<a href="{% url 'about' %}">{{ article.author }}</a></h2>
                            <p>转载请标明出处：<a href="{{ url }}">{{ url }}</a></p>
                        </div>
                        <div style="float: right;display: inline-block;text-align: center;">
                           <p ><a rel="license" href="http://creativecommons.org/licenses/by-nc-sa/4.0/"><img alt="知识共享许可协议" src="http://img.blog.csdn.net/20160827215438167"></a><br>本作品采用<a rel="license" href="http://creativecommons.org/licenses/by-nc-sa/4.0/">知识共享署名-非商业性使用-相同方式共享 4.0 国际许可协议</a>进行许可。</p>
                        </div>
                    </div>
                </div>
            <div class="blog__tags">
                <span style="margin-bottom: 10px;display: block" class="glyphicon glyphicon-fire"> 如果您认为本网站的博文质量不错，读后觉得收获很大，不妨小额赞助我一下，让我有动力继续写出高质量的博文！</span>
                    <button class="btn btn-warning" type="button" data-toggle="collapse" data-target="#collapseExample" aria-expanded="false" aria-controls="collapseExample" style="margin-bottom: 10px;margin-top: 2px">
                      打赏
                    </button>
                    <div class="collapse" id="collapseExample">
                      <div class="well">
                        <div class="row" style="margin-top: 20px">
                              <div class="col-xs-6 col-md-6">
                                  <img src="/static/blog/img/wx.png" class="img-rounded">
                                    <h6>微信扫我</h6>
                              </div>
                                <div class="col-xs-6 col-md-6">
                                  <img src="/static/blog/img/zfb.png" class="img-rounded">
                                    <h6>支付宝扫我</h6>
                              </div>
                            </div>
                      </div>
                    </div>
            </div>
                <div class="blog__tags">
                    {% for tag in article.get_tags %}
                        <a href="{% url 'index' %}?tag={{ tag.name }}" class="tags-list__item">#{{ tag.name }}</a>
                    {% endfor %}

                </div>
            <div class="blog__tags" >
                <div style="">
                    <script type="text/javascript">var jd_union_unid="1000244035",jd_ad_ids="505:6",jd_union_pid="CK2q3vHyKxDDhvrcAxoAIPbl4/UDKgA=";var jd_width=960;var jd_height=90;var jd_union_euid="";var p="AhMDVhlaHAESBWVEH0hfIlgRRgYlXVZaCCsfSlpMWGVEH0hfIlAXQBNDYWEZNVsLfWpXBVdDHF5HQWdZF2scARoAVB1bEAoiB1QaWhYHFwZXH2slXVZaCCsQewMiWBFGBiUCFgZcGVocChIDURpZJQMiN2U%3D";</script><script type="text/javascript" charset="utf-8" src="//u-x.jd.com/static/js/auto.js"></script>
                </div>
                <div>
                    <a data-type="3" data-tmpl="800x90" data-tmplid="195" data-rd="2" data-style="2" data-border="1" href="#"></a>
                </div>

            </div>
            <!--PC和WAP自适应版-->
            <div class="blog__tags">

            <!--PC和WAP自适应版-->
            <div id="SOHUCS" sid="{{ article.id }}" style="padding: 0 10px 0 10px"></div>
            <script type="text/javascript">
            (function(){
            var appid = 'cytgiwHpa';
            var conf = 'prod_ea4dd2322ef63884552aba061ad5b1ff';
            var width = window.innerWidth || document.documentElement.clientWidth;
            if (width < 960) {
            window.document.write('<script id="changyan_mobile_js" charset="utf-8" type="text/javascript" src="https://changyan.sohu.com/upload/mobile/wap-js/changyan_mobile.js?client_id=' + appid + '&conf=' + conf + '"><\/script>'); } else { var loadJs=function(d,a){var c=document.getElementsByTagName("head")[0]||document.head||document.documentElement;var b=document.createElement("script");b.setAttribute("type","text/javascript");b.setAttribute("charset","UTF-8");b.setAttribute("src",d);if(typeof a==="function"){if(window.attachEvent){b.onreadystatechange=function(){var e=b.readyState;if(e==="loaded"||e==="complete"){b.onreadystatechange=null;a()}}}else{b.onload=a}}c.appendChild(b)};loadJs("https://changyan.sohu.com/upload/changyan.js",function(){window.changyan.api.config({appid:appid,conf:conf})}); } })();
            </script>

            </div>

            </article>
        </div>
    </section>
    </div>
<script type="text/javascript">
    (function(win,doc){
        var s = doc.createElement("script"), h = doc.getElementsByTagName("head")[0];
        if (!win.alimamatk_show) {
            s.charset = "gbk";
            s.async = true;
            s.src = "https://alimama.alicdn.com/tkapi.js";
            h.insertBefore(s, h.firstChild);
        };
        var o = {
            pid: "mm_54561653_26034128_141932163",/*推广单元ID，用于区分不同的推广渠道*/
            appkey: "",/*通过TOP平台申请的appkey，设置后引导成交会关联appkey*/
            unid: "",/*自定义统计字段*/
            type: "click" /* click 组件的入口标志 （使用click组件必设）*/
        };
        win.alimamatk_onload = win.alimamatk_onload || [];
        win.alimamatk_onload.push(o);
    })(window,document);
</script>
{% endblock %}
{% block js %}
    <script>
        $(function () {
            var testEditormdView2;
            testEditormdView2 = editormd.markdownToHTML("test-editormd-view2", {
                htmlDecode: "style,script,iframe",
                markdownSourceCode: true,
                emoji: true,
                taskList: true,
                tex: true,
                flowChart: true,
                sequenceDiagram: true
            });
            $('#ReplyComment').bind('click', AddComment);
        });

    </script>
    <script type="text/javascript" src="https://assets.changyan.sohu.com/upload/plugins/plugins.count.js"></script>
{% endblock %}
